package com.gxa.scdx.cloud.user.pojo;

import java.util.Date;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * 用户表(User)实体类
 *
 * @author 颜可翔
 * @version 1.0
 * @since 2021-06-22 09:13:11
 */
@ApiModel(value = "User", description = "用户表")
public class User implements Serializable {
    private static final long serialVersionUID = 766212432214200946L;

    public User() {
        System.out.println("User对象初始化");
    }

    /**
     * 用户表主键id
     */
    @ApiModelProperty(name = "id", notes = "用户表主键id", dataType = "Integer", required = true)
    private Integer id;
    /**
     * 用户名称
     */
    @ApiModelProperty(name = "username", notes = "用户名称", dataType = "String", required = true)
    private String username;
    /**
     * 密码
     */
    @ApiModelProperty(name = "password", notes = "密码", dataType = "String", required = true)
    private String password;
    /**
     * 手机号
     */
    @ApiModelProperty(name = "phone", notes = "手机号", dataType = "String", required = true)
    private String phone;
    /**
     * 最后登录时间
     */

    @ApiModelProperty(name = "lastLoginTime", notes = "最后登录时间", dataType = "Date", required = true)
    private Date lastLoginTime;
    /**
     * 账户创建时间
     */
    @ApiModelProperty(name = "createTime", notes = "账户创建时间", dataType = "Date", required = true)
    private Date createTime;
    /**
     * 部门主键id
     */
    @ApiModelProperty(name = "departmentId", notes = "部门主键id", dataType = "Integer", required = true)
    private Integer departmentId;
    /**
     * 权限主键id
     */
    @ApiModelProperty(name = "roleId", notes = "权限主键id", dataType = "Integer", required = true)
    private Integer roleId;

    private Department department;

    private Role role;


    public User(String username, String password) {
        this.username = username;
        this.password = password;
    }

    public Department getDepartment() {
        return department;
    }

    public void setDepartment(Department department) {
        this.department = department;
    }

    public Role getRole() {
        return role;
    }

    public void setRole(Role role) {
        this.role = role;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }


    public String getPhone() {
        return phone;
    }


    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Date getLastLoginTime() {
        return lastLoginTime;
    }

    public void setLastLoginTime(Date lastLoginTime) {
        this.lastLoginTime = lastLoginTime;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Integer getDepartmentId() {
        return departmentId;
    }

    public void setDepartmentId(Integer departmentId) {
        this.departmentId = departmentId;
    }

    public Integer getRoleId() {
        return roleId;
    }

    public void setRoleId(Integer roleId) {
        this.roleId = roleId;
    }


}